package com.wicket.okrcalc.web.contorller;

import cn.hutool.core.bean.BeanUtil;
import com.github.pagehelper.Page;
import com.github.pagehelper.page.PageMethod;
import com.wicket.okrcalc.biz.service.DashboardTargetContentService;
import com.wicket.okrcalc.biz.service.dto.req.*;
import com.wicket.okrcalc.biz.service.dto.res.*;
import com.wicket.okrcalc.common.ro.OkrResult;
import com.wicket.okrcalc.common.util.CommonFunctionHelper;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.validation.annotation.Validated;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @author ：
 * @date ：
 *
 *
 * @version 1.0
 */
@RestController
@RequestMapping("/calc/dashboardTargetContent/")
public class DashboardTargetContentController {

  @Autowired
  DashboardTargetContentService dashboardTargetContentService;
/**
   * D4查询评价模板下不同树单数据点图表列表by内容(公共)
   */
    @PostMapping("queryEvaPersonSingleChartListCom")
    public OkrResult<QueryEvaPersonSingleChartListComRespDto> queryEvaPersonSingleChartListCom(@RequestBody @Validated QueryEvaPersonSingleChartListComReqDto reqDTO){
    return OkrResult.success(dashboardTargetContentService.queryEvaPersonSingleChartListCom(reqDTO));
    }
/**
   * D4查询个人指标排行列表
   */
    @PostMapping("queryMemberObjectiveRankingList")
    public OkrResult<QueryMemberObjectiveRankingListRespDto> queryMemberObjectiveRankingList(@RequestBody @Validated QueryMemberObjectiveRankingListReqDto reqDTO){
    return OkrResult.success(dashboardTargetContentService.queryMemberObjectiveRankingList(reqDTO));
    }
}
